
<title>项目 - <?php echo TITLE_DEVELOPER;?></title>
<link rel="stylesheet" href="<?php echo URL_ASSET_ROOT;?>css/private/project/list.css">

<div class="middle">
    <div class="middle-section">
        <div class="middle-container">

            <div class="form-inline" style="margin-top: 30px;">
                <button id="add_project_btn" class="btn btn-default btn-lg">+ 创建项目</button>
            </div>

            <div class="tab-content">
                <div role="tabpanel" class="tab-pane fade in active" id="demo" aria-labelledby="demo-tab">
                    <div class="row">
                        <?php

                        if($listArr) {
                            echo '<div class="col-md-12"><table class="table table-striped table-hover text-left" style="margin-top:40px;">';

                            echo '<thead><tr>
                                        <th class="col-md-1 project-list-title">编号</th>
                                        <th class="col-md-3 project-list-title">项目名称</th>
                                        <th class="col-md-3 project-list-title">创建时间</th>
                                        <th class="col-md-1 project-list-title">操作</th>
                                    </tr></thead>';

                            foreach($listArr as $key => $value) {
                                echo '
                            <tr>
                                <th class="col-md-1 project-list-num">'.$key.'</th>
                                <th class="col-md-3 project-list-name"><a class="navbar-link" href="'.URL_ITEM_LIST.'/projectId/'.$value->id.'">'.$value->name.'</a></th>
                                <th class="col-md-3 project-list-time">'.date('Y-m-d H:i:s', $value->time).'</th>
                                <th class="col-md-1 project-list-operate">
                                    <a href="/project/delete/projectId/'.$value->id.'">
                                        <button type="button" class="btn btn-default btn-xs" style="outline: none">删除</button>
                                    </a>
                                </th>
                            </tr>
                        ';
                            }
                            echo '</table></div>';
                        }
                        ?>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>

<div id="cover" class="cover">
    <img  id="cover_close_btn" class="cover_close_btn" src="<?php echo URL_ASSET_ROOT;?>img/public/icon_close.png"/>
    <div id="form_container" class="form_container form-inline">
        <input id="project_input" type="text" class="form-control project-input input-lg" placeholder="请输入项目名称">
        <button id="confirm_project_btn" class="btn btn-default btn-lg">确定</button>
    </div>
    <div id="note_container" class="note_container">正在创建，请稍等...</div>
</div>

<script type="text/javascript" src="<?php echo URL_ASSET_ROOT;?>js/lib/jquery/jquery-2.1.3.min.js"></script>
<script type="text/javascript" src="<?php echo URL_ASSET_ROOT;?>js/lib/bootstrap/bootstrap-3.3.7.min.js"></script>
<script type="text/javascript" src="<?php echo URL_ASSET_ROOT;?>js/private/project/list.min.js"></script>